package xyz.poke.business.tool.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * @author 迫壳
 * @date 2024/3/19 20:40
 */
@Data
public class TreeDTO implements Serializable {

    private NodeDTO currentNode;

    private List<TreeDTO> children;

    public TreeDTO() {
        currentNode = new NodeDTO();
        children = new ArrayList<>();
    }

    @Data
    @NoArgsConstructor
    @AllArgsConstructor
    public static class NodeDTO {

        private String code;

        private String name;

        private String fatherCode;

        private Boolean selected;

    }

}
